<template>
  <div class="about">
    <p>{{detail}}</p>
    <img v-if="detail" :src="detail.imgUrl" alt="">
  </div>
</template>

<script lang="ts">
import { defineComponent } from "vue";
import getPhoneDetail from "./detail";
export default defineComponent({
  name: "Detail",
  setup() {
    const aa = getPhoneDetail();
    const bb = getPhoneDetail();
    const cc = getPhoneDetail();
    const detail = getPhoneDetail();
    setTimeout(() => {
      console.log(aa);
      console.log(bb);
      console.log(cc);
      console.log(detail);
    }, 3000);
    return {
      detail,
    };
  },
});
</script>

<style lang="less">
img {
  width: 100px;
  height: 100px;
}
</style>
